# -*- coding: utf-8 -*-
# @Time    : 2021/3/20 0020 15:42
# @Author  : 蒋才果
# @Email   : 1476235300@qq.com
# @File    : 3-19homework.py
# @Software: PyCharm

# for i in range(3):
#     a = 5
#     b = input("输入一个数字：")
#     if b.strip('-').isdigit():
#         if int(b) == a:
#             print(f"你用了{i + 1}次机会猜中了")
#             break
#         elif a > int(b):
#             print("小了")
#         elif a < int(b):
#             print("大了")
#         else:
#             print(f"你还剩余{3 - i - 1}次机会")
#     else:
#         print("你输入的不是数字")
# else:
#     print("蠢猪")

#  打印1-50整数的和##
# a = 1
# for i in range(49):
#     if i == 49:
#         print("完")
#         break
#     else:
#         a += i + 2
# print(a)

# 1-100质数#
# from math import sqrt
# result = ""
# for i in range(2,101):
#     for j in range(2,i):
#         if i%j==0:
#             break
#     else:
#          result += str(i)
# print(result)
# 根据分数定等级
# num1 = input("请输入0-100的数字：")
# if num1.lstrip('-').isdigit():
#     if 100> int(num1) >0:
#         if 85<= int(num1) <=100:
#             print("优秀")
#         elif 60<= int(num1) <85:
#             print("良好")
#         else:
#             print("不及格")
#     else:
#         print("超出成绩范围")
# else:
#      print("你输入的不是数字")
